CC = g++
CFLAGS = -g -I. -Wall -pedantic -std=c++98 -Wextra
OBJECTS = main.o sgf_lexer.o SGFToken.o

all: parser

parser: $(OBJECTS)
	$(CC) $(OBJECTS) -o parser

main.o: main.cpp sgf_lexer.h
	$(CC) $(CFLAGS) -c main.cpp

sgf_lexer.o: sgf_lexer.cpp sgf_lexer.h SGFToken.h
	$(CC) $(CFLAGS) -c sgf_lexer.cpp

SGFToken.o: SGFToken.h
	$(CC) $(CFLAGS) -c SGFToken.cpp
